<!DOCTYPE html>
<html lang="en">
   <head>
      <meta charset="UTF-8">
      <title>时间戳</title>
   </head>
   <body>
      <script>
         const date = new Date()
         console.log(date.getTime())
         console.log(Date.now())
         console.log(+new Date())
      </script>
   </body>
</html>